stage("Unit tests") {
try {
shwrap("""
- make check
+ make -C target/c check
""")
} finally {
shwrap("cat test-suite.log || true")
}
}
stage("Build installed tests") {
- shwrap("make -C tests/kolainst")
+ shwrap("""
+ make -C tests/kolainst
+ """)
}
stage("Generate artifacts") {
shwrap("""
- make install DESTDIR=\$(pwd)/installed/rootfs
+ make -C target/c install DESTDIR=\$(pwd)/installed/rootfs
make -C tests/kolainst install DESTDIR=\$(pwd)/installed/tests
bash -c '. /usr/lib/os-release && echo \$VERSION_ID' >\$(pwd)/installed/buildroot-id
""")
- name: Build libostree
run: ./ci/build.sh
- name: Install libostree
- run: make install
+ run: make -C target/c install
- name: Rust build
run: cargo test --no-run --verbose --features=${{ env['LATEST_LIBOSTREE'] }}
- name: Run tests
OS_ID_LIKE=$(. /etc/os-release; echo $ID ${ID_LIKE:-})
OS_VERSION_ID=$(. /etc/os-release; echo $VERSION_ID)
+# Drop our content underneath target/ by default as it's already
+# ignored by rust
+BUILDDIR=target/c
+
pkg_upgrade() {
dnf -y distro-sync
}
build() {
env NOCONFIGURE=1 ./autogen.sh
- ./configure --sysconfdir=/etc --prefix=/usr --libdir=/usr/lib64 "$@"
- make V=1
+ mkdir -p target/c
+ (cd target/c && ../../configure --sysconfdir=/etc --prefix=/usr --libdir=/usr/lib64 "$@")
+ make -C target/c V=1
}
pkg_install() {
FROM quay.io/coreos-assembler/fcos-buildroot:testing-devel as builder
WORKDIR /src
COPY . .
-RUN env ./ci/build.sh && make install DESTDIR=/cosa/component-install
+RUN ./ci/build.sh
+RUN make -C target/c install DESTDIR=/cosa/component-install
RUN make -C tests/kolainst
RUN make -C tests/kolainst install DESTDIR=/cosa/component-tests
# Uncomment this to fake a build to test the code below